Multiple JAVA virtual machines (JVMs) may concurrently execute on the same computing device. Each such JVM may execute within a separate process (referred to herein as a “JVM process”) that is isolated from the other JVM processes that concurrently execute on the same computing device. Each of these JVM processes may consume a substantial amount of the computing device's memory. The quantity of memory that each JVM process consumes can limit the number of JVM processes that can be executed concurrently on the computing device.
A JVM process needs to load certain classes when that JVM process starts up. Loading these classes can require a substantial amount of time. When multiple JVM processes are to be executed concurrently, the amount of time required for all of these JVM processes to load such classes can become prohibitive.
Normally, when a JVM process starts up, the JVM process needs to load a class that is associated with a reference. The reference may be a symbolic name such as “java.lang.String,” for example. The JVM process engages in a lookup process which involves a class loader. The class loader loads, from a file system, bytes to which the class corresponds. The class loader defines the class. The JVM process processes these bytes and loads these bytes into the JVM process' internal data structures (e.g., lookup tables) for fast access.
These data structure are typically stored in memory that has been allocated within the JVM process' private heap (i.e., private memory region). The JVM process may allocate this memory using the “malloc” call, for example. This memory region is writable, private memory that is not shared.